#pragma once

#include <stdlib.h>
#include <stdio.h>
#include <string>
#include <list>
#include <sqlite3.h>

#define _SYSCOMLIBPRO_

#include <StorageSqlitePro.h>

class STORAGESQLITEPRODLLEXPORT   CSqliteDb
{
public:
	CSqliteDb();
	~CSqliteDb(void);
	//static csysstorage * createstorage();
	virtual int opendb(const char * db);
	virtual int closedb();
	virtual int dbbegintran(char * errMsg);
	virtual int dbcommittran(char * errMsg);
	virtual int getdatabases(std::list<int ,char * > & dblist,char * errMsg);
	virtual int gettableses(std::list<int ,char * > & dblist,char * errMsg);
	virtual int getconlumes(const char * table,std::list<int ,char * > & dblist,char * errMsg);
	virtual int execsqlscript(const char * sql,char * errMsg);
	virtual int execsqlscript(const char * sql,int (*callback)(void*,int,char **,char **),
			void*,char * errMsg);
	virtual int execsqlscript(const char * sql,sqlite3_stmt *pstmt,const char * errMsg);
};

